<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>用户信息</title>
<jsp:include page="/common.jsp" />
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
<script type="text/javascript">
	$(document)
			.ready(
					function() {
						$("#btnSubmit").click(function(){
							var options = { 
									url:"${pageContext.request.contextPath}/system/user/edit.htm",
									onSubmit:function(){return validateRequiredFields($("#addform")[0]);},
						            success:function(data) { 
						            	switch(data){
						            	case "0":
						            		$.messager.alert("提示","操作失败.","error");
						            		break;
						            	case "1":
						            		$.messager.alert("提示","操作成功!","info",function(){
						            			window.location.href = "${pageContext.request.contextPath}/system/user/toEdit.htm";
						            		});
						            		break;
						            	}
						            } 
						        };
							$("#addform").form(options);
							$("#addform").submit();
						});
					});

</script>
<link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath }/resource/form.css">
</head>
<body>
	<form id="addform" method="post">
		<table>
			<tr>
				<td id="${userFormBean.user.id }">用户名</td>
				<td><input type="text" name="user.userName" disabled
					value="${userFormBean.user.userName }" /></td>
			</tr>
			<tr>
				<td>手机号码</td>
				<td><input type="text" name="user.userPhone"
					value="${userFormBean.user.userPhone }" alt="手机号码#false#Int"/></td>
			</tr>
			<tr>
				<td>联系地址</td>
				<td><input type="text" name="user.userAddress"
					value="${userFormBean.user.userAddress }" /></td>
			</tr>
			<tr>
				<td>备注信息</td>
				<td><form:textarea path="userFormBean.user.userNote"/>
				<%-- <input type="text" name="user.userNote"
					value="${userFormBean.user.userNote }" /></td> --%>
			</tr>
			<tr>
				<td>&nbsp;</td>
				<td ><input id="btnSubmit" type="button" value="提交" />&nbsp;<input
					type="reset" value="重置" /></td>
			</tr>
		</table>

	</form>
</body>
</html>